FollowMePilotingItf

Piloting interface used to make the drone follow some (possibly moving) target.

Availability

This interface will be unavailable until a specific set of conditions are met:

  • the drone must be flying,
  • the drone must be properly calibrated,
  • the drone must have sufficient GPS location information,
  • the drone must be sufficiently far above the ground,
  • the drone must be sufficiently far away from the target,
  • the application must provide sufficient information to the drone so that it can identify and track the target (see Target selection for further information on how to provide target tracking information.)
All unsatisfied conditions are reported by this interface, when unavailable, so that the application can inform the user and take appropriate measures to satisfy those conditions as appropriate. Once all conditions are satisfied, then the interface will become available and can be activated so that the drone starts following the target.

Note that this interface, even while available or active may become unavailable back again, as soon as any of those conditions is not satisfied anymore.

Mode

This interface supports different modes of operation. This may be configured through the mode setting, regardless of interface availability. Mode changes will be applied immediately in case the interface is currently active, without the need to activate it again. Note also that this setting is not persisted.

Alerts and behavior

When available or active, this interface may also alert about specific conditions that hinders optimally accurate tracking of the target, although tracking remains feasible under such conditions:

  • TODO : refine and list exactly which cases can be forwarded as an 'alert' from the drone.
The application may use such alerts to inform the user and take appropriate measures to improve tracking performance.

This interface will also report when such conditions actually force the drone to adopt a downgraded behavior. For example, some conditions may force the drone to remain only stationary instead of following the target when it moves.

Movement

When this interface is active, the drone will fly autonomously to follow the moving target as the current mode permits it, unless manually instructed to move using this interface's setPitch, setRoll or setVerticalSpeed piloting commands. In any case, the drone will always try to follow the target and may thus move independently of the provided piloting commands to do so.

Target selection

In order for this interface to be available, the application must instruct the drone how to identify and track the desired target. To do so, the TargetTracker peripheral must be used.

Using this peripheral, the application may:

  • Require controller (remote control, or user device) barometer and location information to be sent regularly to the drone. In case sent information is sufficiently accurate, it may be sufficient to allow the drone to track the controller, in which case, provided other requirements are satisfied, the interface will become available and, when active, will make the drone follow the controller.
  • Provide external information about where the desired target is located, its direction and current movement. Such information may for example come from results of image processing applied to the drone video stream. In case sent information is sufficiently accurate and coherent, it may be sufficient to allow the drone to track the desired target, in which case, provided other requirements are satisfied, the interface will become available and, when active, will make the drone follow the desired target.

Note that both controller barometer/location information and external target information may be sent to the drone at the same time, provided they give coherent positioning information on the SAME target. For instance, it is possible to perform image processing on the drone video stream to identify the controller and send the results to the drone, along with controller barometer/location updates, for better tracking performance. However, care must be taken not to provide incoherent information, such as forwarding controller/barometer location and, as the same time, external information on a different target than the controller; behavior is undefined in such a case.

This piloting interface can be obtained from a drone using:

drone.getPilotingItf(FollowMePilotingItf.class)

See also

com.parrot.drone.groundsdk.device.Drone

Types

Link copied to clipboard
Follow-me actual behavior.
Link copied to clipboard
enum Mode
Follow-me operating mode.

Functions

Link copied to clipboard
abstract fun activate(): Boolean
Activates this piloting interface.
Link copied to clipboard
abstract fun deactivate(): Boolean
Deactivates this piloting interface.
Link copied to clipboard
Tells why this piloting interface is currently be unavailable.
Link copied to clipboard
Informs about the current behavior of the follow-me piloting interface.
Link copied to clipboard
Alerts about issues that currently hinders optimal behavior of this interface.
Link copied to clipboard
Gets the piloting interface's current state.
Link copied to clipboard
Gives access to the operating mode setting.
Link copied to clipboard
abstract fun setPitch(@IntRange(from = "-100", to = 100) pitch: Int)
Sets the current pitch value.
Link copied to clipboard
abstract fun setRoll(@IntRange(from = "-100", to = 100) roll: Int)
Sets the current roll value.
Link copied to clipboard
abstract fun setVerticalSpeed(@IntRange(from = "-100", to = 100) verticalSpeed: Int)
Set the current vertical speed value.